package org.wangchaocheng.cloudgallery.authentication.executor.command;

import lombok.RequiredArgsConstructor;
import org.wangchaocheng.cloudgallery.authentication.strategy.AuthenticationStrategy;
import org.wangchaocheng.cloudgallery.authentication.strategy.AuthenticationStrategyFactory;
import org.wangchaocheng.cloudgallery.common.annotation.CommandExecutor;
import org.wangchaocheng.cloudgallery.commond.authentication.AuthenticationCmd;

/**
 * 认证登录命令执行器
 *
 * @author wangchaocheng
 * @date 2025/04/22
 */
@CommandExecutor
@RequiredArgsConstructor
public class AuthenticationCmdExe {

    private final AuthenticationStrategyFactory authenticationStrategyFactory;

    public void execute(AuthenticationCmd cmd) {
        AuthenticationStrategy authenticationStrategy = authenticationStrategyFactory.getAuthenticationStrategy(cmd.getAuthType());
        boolean authenticateResult = authenticationStrategy.authenticate(cmd);


    }


}
